#include <iostream>
#include <set>
#include <string>
using namespace std;

int main(int argc, char const *argv[])
{
    multiset<string> cities{
        "shanghai", "guangzhou", "beijing", "chongqing", "suzhou", "shanghai"};

    for (const auto &elem : cities)
    {
        cout << elem << " ";
    }
    cout << endl;

    cities.insert({"suzhou", "haerbin", "gansu"});

    for (const auto &elem : cities)
    {
        cout << elem << " ";
    }
    cout << endl;
    
    return 0;
}
